package com.sti.framework.core.web;

import org.springframework.web.bind.annotation.RestControllerAdvice;

/**
 * 全局异常处理，参考父类
 */
@RestControllerAdvice
public class GlobalRestControllerException extends GlobalRestControllerExceptionHandler {

    /**
     * 请求参数错误
     * @param e
     * @return
     *
     *
     * @ResponseStatus(HttpStatus.OK)
     * @ExceptionHandler(MethodArgumentNotValidException.class)
     * public ResponseBodyEntity MethodArgumentNotValidException(MethodArgumentNotValidException e) {
     * e.printStackTrace();
     * return ResponseBodyEntity.fail(ResponseBodyEntity.ResponseStatus.USER_ERROR_21400, ResponseBodyEntity.ResponseStatus.USER_ERROR_21400.getMsg() + "（" +e.getAllErrors().get(0).getDefaultMessage()+"）");
     * }
     */

}
